const path = require('path');
const {LifeCircleService,ReadJsonFileList} = require("../service/ConfigService")
const {EmailService} = require("../service/EmailService")

//读取配置文件
const allConfig = ReadJsonFileList(path.join(__dirname,"../config"),['account','runtime']);

(async ()=>{  

	if(allConfig.account.email){

		const {user,pass} = allConfig.account.email;

		const emailService = new EmailService(user,pass);

		const info = await emailService.email.sendMsg(this.user,"下单成功",JSON.stringify(data))

		console.log("下单信息",info)

	}

 })();
